package com.sys.goods.pojo;


import java.util.Date;
import java.util.Map;
import java.util.TreeMap;

import com.sys.common.pojo.BasePojo;

/**
 * 盲盒标
 * 
 * @author lby
 *
 */
public class ABlindbox extends BasePojo<ABlindbox>
{
	private int blindBoxId;
	private int blindBoxNumber;
	private double blindBoxPrices;
	private String blindBoxIntroduce;
	private String blindBoxPicture;
	private byte status;
	private Date createTime;
	private Date updateTime;
	private Date pubTime;

	private String statusStr;

	/*
	 * 方便枚举项在网页上显示出来 键为值(数字), 值为字符串描述 只提供get方法
	 */
	private Map<String, String> enumsMap = new TreeMap<String, String>();

	public Map<String, String> getEnumsMap()
	{
		// 根据状态值获取字符串描述
		ABlindboxEnum[] ablindboxsenum = ABlindboxEnum.values();
		for (int i = 0; i < ablindboxsenum.length; i++)
		{
			ABlindboxEnum ablindboxsEnum = ablindboxsenum[i];
			String key = ablindboxsEnum.toString();
			enumsMap.put(key + "-" + ablindboxsEnum.getStatus() + "", ablindboxsEnum.getName());
		}
		return enumsMap;
	}

	public String getStatusStr()
	{
		ABlindboxEnum[] values = ABlindboxEnum.values();
		for (int i = 0; i < values.length; i++)
		{
			ABlindboxEnum ablindboxEnumTemp = values[i];
			if (ablindboxEnumTemp.toString().startsWith("STATUS"))
			{
				if (ablindboxEnumTemp.getStatus() == this.status)
				{
					this.statusStr = ablindboxEnumTemp.getName();
				}
			}
		}

		return statusStr;
	}

	public int getBlindBoxId()
	{
		return blindBoxId;
	}

	public void setBlindBoxId(int blindBoxId)
	{
		this.blindBoxId = blindBoxId;
	}

	public int getBlindBoxNumber()
	{
		return blindBoxNumber;
	}

	public void setBlindBoxNumber(int blindBoxNumber)
	{
		this.blindBoxNumber = blindBoxNumber;
	}

	public double getBlindBoxPrices()
	{
		return blindBoxPrices;
	}

	public void setBlindBoxPrices(double blindBoxPrices)
	{
		this.blindBoxPrices = blindBoxPrices;
	}

	public String getBlindBoxIntroduce()
	{
		return blindBoxIntroduce;
	}

	public void setBlindBoxIntroduce(String blindBoxIntroduce)
	{
		this.blindBoxIntroduce = blindBoxIntroduce;
	}

	public String getBlindBoxPicture()
	{
		return blindBoxPicture;
	}

	public void setBlindBoxPicture(String blindBoxPicture)
	{
		this.blindBoxPicture = blindBoxPicture;
	}

	public byte getStatus()
	{
		return status;
	}

	public void setStatus(byte status)
	{
		this.status = status;
	}

	public Date getCreateTime()
	{
		return createTime;
	}

	public void setCreateTime(Date createTime)
	{
		this.createTime = createTime;
	}

	public Date getUpdateTime()
	{
		return updateTime;
	}

	public void setUpdateTime(Date updateTime)
	{
		this.updateTime = updateTime;
	}

	public Date getPubTime()
	{
		return pubTime;
	}

	public void setPubTime(Date pubTime)
	{
		this.pubTime = pubTime;
	}

}
